<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
	<link rel="shortcut icon" href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/logo.png"/>
	<title>{{.title}}</title>
	<script src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/frame/mui/js/mui.min.js"></script>
	<link href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/frame/mui/css/mui.min.css" rel="stylesheet" />
	<link href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/css/other/all.css" rel="stylesheet" />
	<link href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/css/other/app.css?v=12" rel="stylesheet" />
	<link href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/css/app.css?v=2" rel="stylesheet" />
	<link rel="stylesheet" href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/frame/sui/css/SUI.css">
	<link href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/css/other/ydui.css?rev=@@hash" rel="stylesheet" />
	<link rel="stylesheet" href="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/font/iconfont.css">
</head>
<style type="text/css">
	.mui-table-view-cell>a:not(.mui-btn){
		margin: -12px -20px;
	}
	body { overflow: auto;}
	.orderlist{overflow: hidden;}
</style>
<body>
<div class="mui-content">
<div class="user">
	<header>
		<div class="vipcard">
			<h1>
				<a class="fr" href="/mobile/my/info"><i class="mui-icon iconfont fs-20" style="color: #fff;">&#xe7b2;</i></a>
			</h1>
			<div>
				<a class="left" href="/mobile/my/info">
					<img class="pic" src="{{.info.pathname}}">
					<div class="title">
						<h6 class="overpl1">{{.info.monicker}}</h6>
						{{if .info.vname}}
						<img src="{{.info.vpath}}">
						{{else}}
						<img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/tcvip_b.png">
						{{end}}
					</div>
				</a>
				<a href="/mobile/my/money" class="jf">
					<dl class="integral" id="integral">
						<dt class="iconfont">&#xe652;</dt>
						<dd>
							<p>我的余额</p>
							<p>{{.info.money}}元</p>
						</dd>
						<dd class="iconfont">&#xe698;</dd>
					</dl>
				</a>
			</div>
			<ul>
				<li>
					<a href="/mobile/my/collect">
						<p>{{.collect}}</p>
						<span>收藏夹</span>
					</a>
				</li>
				<li>
					<a href="/mobile/my/focus">
						<p>{{.focus}}</p>
						<span>关注店铺</span>
					</a>
				</li>
				<li>
					<a href="/mobile/my/foot">
						<p>{{.read}}</p>
						<span>足迹</span>
					</a>
				</li>
			</ul>
		</div>
	</header>
	<div class="myorder mt-10">
		<h1>
			<a href="/mobile/my/order">
				我的订单
				<i class="mui-icon iconfont icon-31fanhui2 fr fs-12"></i>
				<span class="fr">查看全部订单</span>
			</a>
		</h1>
		<div class="orderlist">
			<div>
			<a href="/mobile/my/order?status=1">
				<div>
					<img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/fk.png">
					{{if .order1}}{{if ne .order1 "0"}}<span>{{.order1}}</span>{{end}}{{end}}
				</div>
				<p>待付款</p>
			</a>
			</div>
			<div>
			<a href="/mobile/my/order?status=2">
				<div>
					<img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/fh.png">
					{{if .order2}}{{if ne .order2 "0"}}<span>{{.order2}}</span>{{end}}{{end}}
				</div>
				<p>待发货</p>
			</a>
			</div>
			<div>
			<a href="/mobile/my/order?status=3">
				<div>
					<img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/sh.png">
					{{if .order3}}{{if ne .order3 "0"}}<span>{{.order3}}</span>{{end}}{{end}}
				</div>
				<p>待收货</p>
			</a>
			</div>
			<div>
			<a href="/mobile/my/order?status=4">
				<div>
					<img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/pj.png">
					{{if .order4}}{{if ne .order4 "0"}}<span>{{.order4}}</span>{{end}}{{end}}
				</div>
				<p>待评价</p>
			</a>
			</div>
			<div>
			<a href="/mobile/my/order?status=6">
				<div>
					<img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/tk.png">
				</div>
				<p>退换货</p>
			</a>
			</div>
		</div>
	</div>
</div>
<div class="myToolBox">
	<p>我的工具</p>
	<dl class="goto" href="/mobile/my/integral">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/integral.png" alt=""></dt>
		<dd>积分商城</dd>
	</dl>
	<dl class="goto" href="/mobile/my/coupon">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/coupon.png" alt=""></dt>
		<dd>卡券包</dd>
	</dl>
	<dl class="goto" href="/mobile/my/address">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/address.png" alt=""></dt>
		<dd>收货地址</dd>
	</dl>
	<dl class="goto" href="/mobile/my/invoice">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/invoice.jpg" alt=""></dt>
		<dd>发票信息</dd>
	</dl>
	<dl class="goto" href="/mobile/my/evaluation">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/reply.png" alt=""></dt>
		<dd>我的评价</dd>
	</dl>
	<dl class="goto" href="/mobile/my/message">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/msg.png" alt=""></dt>
		<dd>我的消息</dd>
	</dl>
	<dl class="goto" id="promotion">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/share.png" alt=""></dt>
		<dd>推广管理</dd>
	</dl>
	<dl class="goto" id="distribution">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/fx.png" alt=""></dt>
		<dd>分销管理</dd>
	</dl>
	{{if eq .info.driver "1"}}
	<dl class="goto" href="/mobile/my/driver">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/driver.png" alt=""></dt>
		<dd>提货管理</dd>
	</dl>
	{{end}}
	{{if eq .info.isshop2 1}}
	<dl class="goto" href="/mobile/my/shop">
		<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/applystore.png" alt=""></dt>
		<dd>店铺管理</dd>
	</dl>
	{{else}}
		{{if eq .info.isshop 0}}
		<dl class="goto" href="/mobile/my/shop_add">
			<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/applystore.png" alt=""></dt>
			<dd>店铺申请</dd>
		</dl>
		{{else}}
		<dl class="goto" id="shop">
			<dt><img src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/img/my/applystore.png" alt=""></dt>
			<dd>店铺管理</dd>
		</dl>
		{{end}}
	{{end}}
</div>	
{{if .shop}}
<div class="myStore">
	<p><span>我的店铺</span></p>
	<dl>
		<dt>{{.shop.moneysum}}元</dt>
		<dd>销售量</dd>
		<dd>今日销售总额</dd>
	</dl>
	<dl>
		<dt>{{.shop.num}}笔</dt>
		<dd>订单量</dd>
		<dd>今日付款订单</dd>
	</dl>
	<div><a href="/mobile/my/myshop"><span>查看更多</span></a></div>
</div>
{{end}}
</div>
<nav class="mui-bar mui-bar-tab">
    <a class="mui-tab-item" href="/mobile/index">
        <span class="mui-icon iconfont icon-home2"></span>
        <span class="mui-tab-label">首页</span>
    </a>
    <a class="mui-tab-item" href="/mobile/column">
        <span class="mui-icon iconfont icon-liebiao"></span>
        <span class="mui-tab-label">分类</span>
    </a>
    <!-- <a class="mui-tab-item" href="/mobile/active">
        <span class="mui-icon iconfont icon-tianmaohaoquan"></span>
        <span class="mui-tab-label">活动</span>
    </a> -->
    <a class="mui-tab-item" href="/mobile/shopcar">
        <span class="mui-icon iconfont icon-gouwucheman"></span>
        <span class="mui-tab-label">购物车</span>
    </a>
    <a class="mui-tab-item mui-active" href="/mobile/my">
		<span class="mui-icon iconfont icon-kefuyouxian"></span>
		<span class="mui-tab-label">我的</span>
	</a>
</nav>
<script src="https://tcsc.oss-cn-hangzhou.aliyuncs.com/static/wechat/frame/sui/js/SUI.js"></script>
{{template "wechat/public/share.html" .}}
<script>
	var shop={{.info.isshop}};
	var shopd=document.getElementById('shop')
	if (shopd){
		shopd.addEventListener('tap',function(){
			if(shop==1){
					window.location.href="/mobile/my/myshop"
			}else if(shop==2){
				mui.alert("您的申请已经提交,请耐心等待~","提示")
			}else if(shop==3){
				mui.confirm("您的申请未通过,前往修改资料吗?","提示",function(res){
					if(res.index){
						mui.closePopups()
						window.location.href="/mobile/my/shop_add"
					}
				})
			}
		})
	}

	var type={{.info.type}};
	document.getElementById('promotion').addEventListener('tap',function(){
		if(type==0){
			mui.confirm("您还不是推广员,前往申请吗?","提示",function(res){
				if(res.index){
					mui.closePopups()
					window.location.href="/mobile/my/promotion_apply"
				}
			})
		}else if(type==2){
			mui.alert("您已经是分销员了~","提示")
		}else if(type==1){
				window.location.href="/mobile/my/promotion"
		}else if(type==3){
			mui.alert("您的申请已经提交,请耐心等待~","提示")
		}else if(type==4){
			mui.confirm("您的申请未通过,前往修改资料吗?","提示",function(res){
				if(res.index){
					mui.closePopups()
					window.location.href="/mobile/my/promotion_apply"
				}
			})
		}
	})
	var typed={{.info.typed}};
	document.getElementById('distribution').addEventListener('tap',function(){
		if(typed==0){
			mui.confirm("您还不是分销员,前往申请吗?","提示",function(res){
				if(res.index){
					mui.closePopups()
					window.location.href="/mobile/my/distribution_apply"
				}
			})
		}else if(type==1){
			mui.alert("您已经是推广员了~","提示")
		}else if(typed==2){
				window.location.href="/mobile/my/distribution"
		}else if(typed==3){
			mui.alert("您的申请已经提交,请耐心等待~","提示")
		}else if(typed==4){
			mui.confirm("您的申请未通过,前往修改资料吗?","提示",function(res){
				if(res.index){
					mui.closePopups()
					window.location.href="/mobile/my/distribution_apply"
				}
			})
		}
	})
    mui.init({
        swipeBack:false //启用右滑关闭功能
    });
    mui('.mui-tab-item').each(function () {
        this.addEventListener('tap',function () {
            var url = this.getAttribute('href');
            window.location.href=url;
        })
    });
    var flag = 0;
	function start(){
		var laba = document.getElementById("laba");
		if (!flag){
			laba.style.color = "#fef8d9";
			flag = 1;
		}else{
			laba.style.color = "";
			flag = 0;
		}
		setTimeout("start()",500);
	}
    // start();
</script>
<div class="mt-statistics">统计代码</div>
</body>
</html>
